﻿<?xml version="1.0" encoding="utf-8"?>
<!DOCTYPE xsl:stylesheet  [
	<!ENTITY nbsp   "&#160;">
	<!ENTITY copy   "&#169;">
	<!ENTITY reg    "&#174;">
	<!ENTITY trade  "&#8482;">
	<!ENTITY mdash  "&#8212;">
	<!ENTITY ldquo  "&#8220;">
	<!ENTITY rdquo  "&#8221;"> 
	<!ENTITY pound  "&#163;">
	<!ENTITY yen    "&#165;">
	<!ENTITY euro   "&#8364;">
]>
<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform" xmlns:page="urn:page">
    <xsl:output method="html" encoding="utf-8" />
  <xsl:param name="rowcount"/>			<!--数据库总记录数-->
  <xsl:param name="maxrow"/>				<!--每页记录数-->
  <xsl:param name="curpage"/>				<!--当前页码-->
  <xsl:param name="param"/>					<!--引入 param 参数-->
  <xsl:param name="templatename"/>	<!--Label.xml 模块名称-->
  <xsl:param name="orderby"/>				<!--Label.xml orderby 参数-->
  <xsl:param name="where"/>					<!--Label.xml where 参数-->
  <xsl:param name="runtime"/>				<!--运行时长-->
  <xsl:template match="/">
    <table width="100%" border="0" align="center" cellpadding="4" 
cellspacing="1" bgcolor="#E0E0E0" class="infoEdit">
      <form id="form1" name="form1" method="post" action="">
        <tbody>
          <tr bgcolor="#ffffff">
            <td width="100" align="left">编码</td>
            <td align="left"><xsl:value-of select="rows/row/ID"/></td>
          </tr>
          <tr bgcolor="#ffffff">
            <td align="left">菜单名称</td>
            <td align="left"><xsl:if test="count(rows/row)=0">
                <select name="Menu_ID" id="Menu_ID">
                <xsl:value-of select="page:xLoadList('功能菜单选择',0,page:xRequest('mid'))" disable-output-escaping="yes"/>
                </select>
              </xsl:if>
              <xsl:if test="count(rows/row)!=0">
                <xsl:value-of select="rows/row/F_Text"/>
                <input name="Menu_ID" type="hidden" id="Menu_ID" value="{rows/row/F_Menu_ID}">
                </input>
              </xsl:if></td>
          </tr>
          <xsl:choose>
            <xsl:when test="rows/row/F_Master_ID&gt;0 and rows/row/F_Group_ID=0">
              <tr bgcolor="#ffffff">
                <td align="left">用户<img src="/Icons/man.gif" align="absmiddle" /></td>
                <td align="left"><xsl:value-of select="rows/row/F_MasterName"/>(<xsl:value-of select="rows/row/F_Master_ID"/>)<input name="Group_ID" type="hidden" value="0" /><input name="Master_ID" type="hidden" value="{rows/row/F_Master_ID}" /></td>
              </tr>
            </xsl:when>
            <xsl:when test="rows/row/F_Master_ID=0 and rows/row/F_Group_ID&gt;0">
              <tr bgcolor="#ffffff">
                <td align="left">用户组<img src="/Icons/mans.gif" align="absmiddle" /></td>
                <td align="left"><xsl:value-of select="rows/row/F_GroupName"/>(<xsl:value-of select="rows/row/cRoleCode"/>)<input name="Group_ID" type="hidden" value="{rows/row/F_Group_ID}" /><input name="Master_ID" type="hidden" value="0" /></td>
              </tr>
            </xsl:when>
            <xsl:otherwise>
              <tr bgcolor="#ffffff">
                <td align="left">选择对象</td>
                <td align="left">
                  <a href="javascript://选择用户组" title="选择用户组" onclick="Element.show('Group_ID');$('Master_ID').value=0;Element.hide('Master_ID')"><img src="/Icons/mans.gif" border="0" align="absmiddle" /></a>
                  
                  &nbsp;&nbsp;
                  <a href="javascript://选择用户" title="选择用户" onclick="Element.show('Master_ID');$('Group_ID').value=0;Element.hide('Group_ID')">
                  <img src="/Icons/man.gif" border="0" align="absmiddle" /></a>
                  <br/>
                  <select name="Group_ID" id="Group_ID" onchange="$('Master_ID').value=0"  style="display:none">
                    <option value="0">----用户组----</option>
                    <xsl:value-of select="page:xLoadList('用户组选择')" disable-output-escaping="yes"/>
                  </select>
                  <select name="Master_ID" id="Master_ID" onchange="$('Group_ID').value=0"  style="display:none">
                    <option value="0">-----用户-----</option>
                    <xsl:value-of select="page:xLoadList('用户选择')" disable-output-escaping="yes"/>
                  </select></td>
              </tr>
            </xsl:otherwise>
          </xsl:choose>
          <tr bgcolor="#ffffff">
            <td align="left">权限</td>
            <td align="left"><label>
              <input name="F_Run" type="checkbox" id="F_Run" value="1" >
              <xsl:if test="rows/row/ACL_Run=1">
                <xsl:attribute name="checked">1</xsl:attribute>
              </xsl:if>
              </input>
              运行</label>
              &nbsp;&nbsp;
              <label>
              <input name="F_Ins" type="checkbox" id="F_Ins" value="1" >
              <xsl:if test="rows/row/ACL_Ins=1">
                <xsl:attribute name="checked">1</xsl:attribute>
              </xsl:if>
              </input>
              增加</label>
              &nbsp;&nbsp;
              <label>
              <input name="F_Edt" type="checkbox" id="F_Edt" value="1" >
              <xsl:if test="rows/row/ACL_Edt=1">
                <xsl:attribute name="checked">1</xsl:attribute>
              </xsl:if>
              </input>
              编辑</label>
              &nbsp;&nbsp;
              <label>
              <input name="F_Del" type="checkbox" id="F_Del" value="1" >
              <xsl:if test="rows/row/ACL_Del=1">
                <xsl:attribute name="checked">1</xsl:attribute>
              </xsl:if>
              </input>
              删除</label>
              &nbsp;&nbsp;
              <label>
              <input name="F_Upd" type="checkbox" id="F_Upd" value="1" >
              <xsl:if test="rows/row/ACL_Upd=1">
                <xsl:attribute name="checked">1</xsl:attribute>
              </xsl:if>
              </input>
               更新</label>
              &nbsp;&nbsp;  </td>
          </tr>
          <tr bgcolor="#ffffff">
            <td align="left">&nbsp;</td>
            <td height="40" align="left"><input name="f" type="hidden" value="@系统菜单权限" /><input class="btnA" id="Submit1" type="button" value="保存" name="Submit1">
              <xsl:attribute name="onclick">if(TM.saveContentCmd('form1',{button:'Submit1',alert:false})==1){TM.pList();}</xsl:attribute>
              </input>
              &nbsp; &nbsp;
              <input class="btnA" type="button" value="取消" name="button" >
              <xsl:attribute name="onclick">TM.closeTab();</xsl:attribute>
              </input>
              &nbsp; &nbsp;
              <input name="editID" type="hidden" id="editID">
              <xsl:attribute name="value"><xsl:value-of select="rows/row/ID"/>
              <xsl:if test="count(rows/row)=0">
                0
              </xsl:if>
              </xsl:attribute>
              </input></td>
          </tr>
        </tbody>
      </form>
    </table>
  </xsl:template>
</xsl:stylesheet>
